package com.qfedu.kbonline.api;

import com.qfedu.kbonline.dto.CodeDto;
import com.qfedu.kbonline.service.intf.CodeService;
import com.qfedu.kbonline.vo.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @program: SuperAsvin
 * @description:
 * @author: ErBa(韩智飞)
 * @create: 2020-09-15 08:04
 **/

@RestController
@RequestMapping("api/code/")
public class CodeApi {

    @Autowired
    private CodeService codeService;

    // 生成代码
    @PostMapping("create.do")
    public R create(@RequestBody CodeDto codeDto) {
        return codeService.create(codeDto);
    }
}
